package com.totcy.atom.view.activity;

import com.totcy.atom.R;
import com.totcy.baselibrary.utils.DateUtils;
import com.totcy.baselibrary.widget.autofitview.AutofitTextView;

import java.util.Calendar;

import butterknife.BindView;

/**
 * description : laohuangli
 *
 * @author : Totcy
 * @date : 2017/12/12 16:19
 * @update : 2017/12/12
 */

public class OldAlmanacActivity extends BaseFullActivity {

    @BindView(R.id.tv_almanac)
    AutofitTextView tvAlmanac;

    @Override
    public String getTitleName() {
        return getString(R.string.old_almanac);
    }

    @Override
    public int getLayoutId() {
        return R.layout.activity_old_almanac;
    }

    @Override
    public void initView() {

        Calendar calendar = Calendar.getInstance();
        tvAlmanac.setText(String.format(getString(R.string.almanac_date_week),
                calendar.get(Calendar.YEAR),
                calendar.get(Calendar.MONTH) + 1,
                calendar.get(Calendar.DAY_OF_MONTH),
                DateUtils.weekArray[calendar.get(Calendar.DAY_OF_WEEK) - 1]
        ));
    }

}
